<%@ page import="java.sql.*, studentportal.*"%>
<%

	String url = "jdbc:mysql://localhost:3306/contilligent";
	Class.forName("com.mysql.jdbc.Driver");		
	Connection con = DriverManager.getConnection(url,"root","root");	
	String vsql = "select * from examination_master";
	Statement stmt = con.createStatement();
	ResultSet rs = stmt.executeQuery(vsql);
	out.println("<html><head><title>Examination Time Table</title></head>");
	out.println("<body background=indtextb.jpg bgcolor=#FFFFFF text=#000000 link=#3366CC vlink=#666666 alink=#996600>");
	out.println("<center><big>Examinations Time Table</big></center><br><br>");
	out.println("<table border=2 width=100% bordercolorlight=#666666 bordercolordark=#000000>");
	ResultSetMetaData rsmd = rs.getMetaData();
	int noc = rsmd.getColumnCount();
	out.println("<tr>");
	for(int i=1;i<=noc;i++) {
			out.println("<td><b>"+rsmd.getColumnName(i)+"</b></td>");
		}
	while(rs.next()) {
		out.println("</tr>");
		out.println("<tr>");	
		for(int i=1;i<=noc;i++) {
			out.println("<td>"+rs.getString(i)+"</td>");
		}
		out.println("</tr>");
	}
	out.println("</table>");
	out.println("</body></html>");
	con.close();
	
%>